package org.example;

import java.util.Scanner;

public class Test3
{
    public static void main(String[] args)
    {
        Scanner sc = new Scanner(System.in);
        int num = sc.nextInt();
        System.out.println(isHuiWenShu(num));
    }

    private static boolean isHuiWenShu(int num)
    {
        int lin = num;
        int num2 = 0;
        while (lin != 0)
        {
            num2 = num2 * 10 + lin % 10;
            lin /= 10;
        }
        return num == num2;
    }
}
